package o;

import android.app.Activity;
import android.content.Context;
import android.text.TextUtils;
import androidx.annotation.NonNull;
import java.util.LinkedHashMap;

public class cil {
    public static void ˋ(Context context, @NonNull cim o_cim) {
        cdk.ॱ("card_item_click", ॱ(context, o_cim));
    }

    private static LinkedHashMap<String, String> ॱ(Context context, cim o_cim) {
        LinkedHashMap<String, String> linkedHashMap = new LinkedHashMap();
        Object ˎ = o_cim.ˎ();
        Object ˏ = o_cim.ˏ();
        Object ˊ = o_cim.ˊ();
        if (!TextUtils.isEmpty(ˎ)) {
            linkedHashMap.put("detailid", ˎ);
        }
        if (!TextUtils.isEmpty(ˏ)) {
            linkedHashMap.put("anchor", ˏ);
        }
        if (TextUtils.isEmpty(ˊ)) {
            Activity activity;
            if (context instanceof Activity) {
                activity = (Activity) context;
            } else {
                context = null;
            }
            linkedHashMap.put("service_type", String.valueOf(dgm.ˎ(activity)));
        } else {
            linkedHashMap.put("service_type", ˊ);
        }
        Logger.ˏ("CardReportClickHelper", "card click report, detailId: " + ˎ + ", anchor: " + ˏ + ", serviceType: " + ˊ);
        return linkedHashMap;
    }
}
